package com.ruoyi.system.service;

import java.util.List;
import java.util.Map;

import com.ruoyi.common.core.page.IServicePlus;
import com.ruoyi.framework.web.domain.CustomerTreeSelect;
import com.ruoyi.system.domain.SysCustomer;
import com.ruoyi.system.domain.vo.CustomerVo;
import com.ruoyi.system.domain.vo.StoreVo;

/**
 * 经销商档案Service接口
 *
 * @author anan
 * @date 2021-03-02
 */
public interface ISysCustomerService extends IServicePlus<CustomerVo>
{
    /**
     * 查询经销商档案
     *
     * @param id 经销商档案ID
     * @return 经销商档案
     */
    public SysCustomer selectSysCustomerById(Long id);

    /**
     * 查询经销商档案列表
     *
     * @param sysCustomer 经销商档案
     * @return 经销商档案集合
     */
    public List<SysCustomer> selectSysCustomerList(SysCustomer sysCustomer);

    /**
     * 查询经销商档案列表
     *
     * @param sysCustomer 经销商档案
     * @return 经销商档案集合
     */
    public List<CustomerVo> selectCustomerList(CustomerVo sysCustomer);
    /**
     * 新增经销商档案
     *
     * @param sysCustomer 经销商档案
     * @return 结果
     */
    public int insertSysCustomer(SysCustomer sysCustomer);

    /**
     * 修改经销商档案
     *
     * @param sysCustomer 经销商档案
     * @return 结果
     */
    public int updateSysCustomer(SysCustomer sysCustomer);

    /**
     * 批量删除经销商档案
     *
     * @param ids 需要删除的经销商档案ID
     * @return 结果
     */
    public int deleteSysCustomerByIds(Long[] ids);

    /**
     * 删除经销商档案信息
     *
     * @param id 经销商档案ID
     * @return 结果
     */
    public int deleteSysCustomerById(Long id);

    public List<SysCustomer> roleCustomerTreeselect(Long roleId);

    public List<CustomerTreeSelect> buildCustomerTreeSelect(List<CustomerVo> customers);

    public List<Map<String,Object>>  selectCustomerListByRoleId(Long roleId);

    public List<Map<String,Object>>  selectCustomerListByUserId(Long userId);

    public List<CustomerVo> conversionList(List<CustomerVo> customers, List<Map<String, Object>> maps, List<StoreVo> storeVos);
}
